package com.bookshop.dao.impl;

import com.bookshop.dao.BaseDao;
import com.bookshop.dao.BookDao;
import com.sun.xml.internal.bind.v2.model.core.ID;

import java.sql.Connection;
import java.sql.SQLException;

public class BookDaoImpl extends BaseDao implements BookDao {
    public BookDaoImpl(Connection conn) {
        super(conn);
    }

    @Override
    public int deleteByCId(Integer cid) throws SQLException {
        String sql="delete from books where CategoryId = ?";
        return super.update(sql, cid);
    }
}
